package com.mdd.mddapiclientsdk;

import com.mdd.mddapiclientsdk.client.MddApiClient;
import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;

/**
 * @author Mdd
 * @Github <a href="https://github.com/mdd123cc"/>
 * @Gitee <a href="https://gitee.com/mdd115192"/>
 */

@Configuration
//读取配置文件配置
@ConfigurationProperties("mddapi.client")
@Data
@ComponentScan
public class MddApiClientConfig {

    private String accessKey;
    private String secretKey;

    @Bean
    MddApiClient getClient(){
       return new MddApiClient(accessKey,secretKey);
    }
}
